function Line(x1,y1,x2,y2){

    var k = (y2 - y1) / (x2 - x1);
    var b = y1 - k * x1;
    var radian = Math.atan2(y2 - y1,x2 - x1);

    this.getK = function(){
        return k;
    }

    this.getB = function(){
        return b;
    }

    this.getX = function(y){
        return (y - b) / k;
    }

    this.getY = function(x){
        return k * x + b;
    }
}